//
//  Room.h
//  Maze1
//
//  Created by Lin Tian on 9/27/11.
//  Copyright 2011 tina. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "Player.h"

@interface Room : NSObject {
    unsigned int _roomId;
    unsigned char _capacity;
    unsigned char _currentNumPlayers;
    unsigned char _numForces;
    unsigned int _mapId;
    Player* builder;
    NSMutableArray *otherPlayersList;
}

-(id)initWithRoomId:(int)roomId;
-(id)initWithRoomId:(int)roomId owner:(Player*)aPlayer;
-(id)initWithOwner:(Player*)aPlayer mapId:(unsigned int)map numForces:(unsigned char)num;
-(void)joinRoomWithPlayer:(Player*)aPlayer;
-(Player*)findPlayerWithPlayerId:(unsigned int)playerId;

@property(nonatomic, assign) unsigned int roomId;
@property(nonatomic, assign) unsigned char capacity;
@property(nonatomic, assign) unsigned char currentNumPlayers;
@property(nonatomic, assign) unsigned char numForces;
@property(nonatomic, assign) unsigned int mapId;
@property(nonatomic, retain) Player* owner;
@property(nonatomic, retain) NSMutableArray *otherPlayersList;

@end
